import request from '@/utils/request'

// 查询开门记录列表
export function listCommunityOpenDoor(query) {
  return request({
    url: '/system/communityOpenDoor/list',
    method: 'get',
    params: query
  })
}

// 查询开门记录详细
export function getCommunityOpenDoor(id) {
  return request({
    url: '/system/communityOpenDoor/' + id,
    method: 'get'
  })
}

// 新增开门记录
export function addCommunityOpenDoor(data) {
  return request({
    url: '/system/communityOpenDoor',
    method: 'post',
    data: data
  })
}

// 修改开门记录
export function updateCommunityOpenDoor(data) {
  return request({
    url: '/system/communityOpenDoor',
    method: 'put',
    data: data
  })
}

// 删除开门记录
export function delCommunityOpenDoor(id) {
  return request({
    url: '/system/communityOpenDoor/' + id,
    method: 'delete'
  })
}

// 导出开门记录
export function exportCommunityOpenDoor(query) {
  return request({
    url: '/system/communityOpenDoor/export',
    method: 'get',
    params: query
  })
}
